3.2.82 \(\int \frac {x^2 (a+b x^2)^2}{(c+d x^2)^2} \, dx\)

Optimal. Leaf size=118 \[ \frac {(b c-a d) (5 b c-a d) \tan ^{-1}\left (\frac {\sqrt {d} x}{\sqrt {c}}\right )}{2 \sqrt {c} d^{7/2}}-\frac {x (b c-a d) (5 b c-a d)}{2 c d^3}+\frac {x^3 (b c-a d)^2}{2 c d^2 \left (c+d x^2\right )}+\frac {b^2 x^3}{3 d^2} \]

________________________________________________________________________________________

Rubi [A]  time = 0.11, antiderivative size = 118, normalized size of antiderivative = 1.00, number of steps used = 4, number of rules used = 4, integrand size = 22, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.182, Rules used = {463, 459, 321, 205} \begin {gather*} \frac {x^3 (b c-a d)^2}{2 c d^2 \left (c+d x^2\right )}-\frac {x (b c-a d) (5 b c-a d)}{2 c d^3}+\frac {(b c-a d) (5 b c-a d) \tan ^{-1}\left (\frac {\sqrt {d} x}{\sqrt {c}}\right )}{2 \sqrt {c} d^{7/2}}+\frac {b^2 x^3}{3 d^2} \end {gather*}

Antiderivative was successfully verified.

[In]

Int[(x^2*(a + b*x^2)^2)/(c + d*x^2)^2,x]

[Out]

-((b*c - a*d)*(5*b*c - a*d)*x)/(2*c*d^3) + (b^2*x^3)/(3*d^2) + ((b*c - a*d)^2*x^3)/(2*c*d^2*(c + d*x^2)) + ((b
*c - a*d)*(5*b*c - a*d)*ArcTan[(Sqrt[d]*x)/Sqrt[c]])/(2*Sqrt[c]*d^(7/2))

Rule 205

Int[((a_) + (b_.)*(x_)^2)^(-1), x_Symbol] :> Simp[(Rt[a/b, 2]*ArcTan[x/Rt[a/b, 2]])/a, x] /; FreeQ[{a, b}, x]
&& PosQ[a/b]

Rule 321

Int[((c_.)*(x_))^(m_)*((a_) + (b_.)*(x_)^(n_))^(p_), x_Symbol] :> Simp[(c^(n - 1)*(c*x)^(m - n + 1)*(a + b*x^n
)^(p + 1))/(b*(m + n*p + 1)), x] - Dist[(a*c^n*(m - n + 1))/(b*(m + n*p + 1)), Int[(c*x)^(m - n)*(a + b*x^n)^p
, x], x] /; FreeQ[{a, b, c, p}, x] && IGtQ[n, 0] && GtQ[m, n - 1] && NeQ[m + n*p + 1, 0] && IntBinomialQ[a, b,
 c, n, m, p, x]

Rule 459

Int[((e_.)*(x_))^(m_.)*((a_) + (b_.)*(x_)^(n_))^(p_.)*((c_) + (d_.)*(x_)^(n_)), x_Symbol] :> Simp[(d*(e*x)^(m
+ 1)*(a + b*x^n)^(p + 1))/(b*e*(m + n*(p + 1) + 1)), x] - Dist[(a*d*(m + 1) - b*c*(m + n*(p + 1) + 1))/(b*(m +
 n*(p + 1) + 1)), Int[(e*x)^m*(a + b*x^n)^p, x], x] /; FreeQ[{a, b, c, d, e, m, n, p}, x] && NeQ[b*c - a*d, 0]
 && NeQ[m + n*(p + 1) + 1, 0]

Rule 463

Int[((e_.)*(x_))^(m_.)*((a_) + (b_.)*(x_)^(n_))^(p_)*((c_) + (d_.)*(x_)^(n_))^2, x_Symbol] :> -Simp[((b*c - a*
d)^2*(e*x)^(m + 1)*(a + b*x^n)^(p + 1))/(a*b^2*e*n*(p + 1)), x] + Dist[1/(a*b^2*n*(p + 1)), Int[(e*x)^m*(a + b
*x^n)^(p + 1)*Simp[(b*c - a*d)^2*(m + 1) + b^2*c^2*n*(p + 1) + a*b*d^2*n*(p + 1)*x^n, x], x], x] /; FreeQ[{a,
b, c, d, e, m, n}, x] && NeQ[b*c - a*d, 0] && IGtQ[n, 0] && LtQ[p, -1]

Rubi steps

\begin {align*} \int \frac {x^2 \left (a+b x^2\right )^2}{\left (c+d x^2\right )^2} \, dx &=\frac {(b c-a d)^2 x^3}{2 c d^2 \left (c+d x^2\right )}-\frac {\int \frac {x^2 \left (3 b^2 c^2-6 a b c d+a^2 d^2-2 b^2 c d x^2\right )}{c+d x^2} \, dx}{2 c d^2}\\ &=\frac {b^2 x^3}{3 d^2}+\frac {(b c-a d)^2 x^3}{2 c d^2 \left (c+d x^2\right )}-\frac {((b c-a d) (5 b c-a d)) \int \frac {x^2}{c+d x^2} \, dx}{2 c d^2}\\ &=-\frac {(b c-a d) (5 b c-a d) x}{2 c d^3}+\frac {b^2 x^3}{3 d^2}+\frac {(b c-a d)^2 x^3}{2 c d^2 \left (c+d x^2\right )}+\frac {((b c-a d) (5 b c-a d)) \int \frac {1}{c+d x^2} \, dx}{2 d^3}\\ &=-\frac {(b c-a d) (5 b c-a d) x}{2 c d^3}+\frac {b^2 x^3}{3 d^2}+\frac {(b c-a d)^2 x^3}{2 c d^2 \left (c+d x^2\right )}+\frac {(b c-a d) (5 b c-a d) \tan ^{-1}\left (\frac {\sqrt {d} x}{\sqrt {c}}\right )}{2 \sqrt {c} d^{7/2}}\\ \end {align*}

________________________________________________________________________________________

Mathematica [A]  time = 0.07, size = 105, normalized size = 0.89 \begin {gather*} \frac {\left (a^2 d^2-6 a b c d+5 b^2 c^2\right ) \tan ^{-1}\left (\frac {\sqrt {d} x}{\sqrt {c}}\right )}{2 \sqrt {c} d^{7/2}}-\frac {x (b c-a d)^2}{2 d^3 \left (c+d x^2\right )}-\frac {2 b x (b c-a d)}{d^3}+\frac {b^2 x^3}{3 d^2} \end {gather*}

Antiderivative was successfully verified.

[In]

Integrate[(x^2*(a + b*x^2)^2)/(c + d*x^2)^2,x]

[Out]

(-2*b*(b*c - a*d)*x)/d^3 + (b^2*x^3)/(3*d^2) - ((b*c - a*d)^2*x)/(2*d^3*(c + d*x^2)) + ((5*b^2*c^2 - 6*a*b*c*d
 + a^2*d^2)*ArcTan[(Sqrt[d]*x)/Sqrt[c]])/(2*Sqrt[c]*d^(7/2))

________________________________________________________________________________________

IntegrateAlgebraic [F]  time = 0.00, size = 0, normalized size = 0.00 \begin {gather*} \int \frac {x^2 \left (a+b x^2\right )^2}{\left (c+d x^2\right )^2} \, dx \end {gather*}

Verification is not applicable to the result.

[In]

IntegrateAlgebraic[(x^2*(a + b*x^2)^2)/(c + d*x^2)^2,x]

[Out]

IntegrateAlgebraic[(x^2*(a + b*x^2)^2)/(c + d*x^2)^2, x]

________________________________________________________________________________________

fricas [A]  time = 0.80, size = 342, normalized size = 2.90 \begin {gather*} \left [\frac {4 \, b^{2} c d^{3} x^{5} - 4 \, {\left (5 \, b^{2} c^{2} d^{2} - 6 \, a b c d^{3}\right )} x^{3} - 3 \, {\left (5 \, b^{2} c^{3} - 6 \, a b c^{2} d + a^{2} c d^{2} + {\left (5 \, b^{2} c^{2} d - 6 \, a b c d^{2} + a^{2} d^{3}\right )} x^{2}\right )} \sqrt {-c d} \log \left (\frac {d x^{2} - 2 \, \sqrt {-c d} x - c}{d x^{2} + c}\right ) - 6 \, {\left (5 \, b^{2} c^{3} d - 6 \, a b c^{2} d^{2} + a^{2} c d^{3}\right )} x}{12 \, {\left (c d^{5} x^{2} + c^{2} d^{4}\right )}}, \frac {2 \, b^{2} c d^{3} x^{5} - 2 \, {\left (5 \, b^{2} c^{2} d^{2} - 6 \, a b c d^{3}\right )} x^{3} + 3 \, {\left (5 \, b^{2} c^{3} - 6 \, a b c^{2} d + a^{2} c d^{2} + {\left (5 \, b^{2} c^{2} d - 6 \, a b c d^{2} + a^{2} d^{3}\right )} x^{2}\right )} \sqrt {c d} \arctan \left (\frac {\sqrt {c d} x}{c}\right ) - 3 \, {\left (5 \, b^{2} c^{3} d - 6 \, a b c^{2} d^{2} + a^{2} c d^{3}\right )} x}{6 \, {\left (c d^{5} x^{2} + c^{2} d^{4}\right )}}\right ] \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(x^2*(b*x^2+a)^2/(d*x^2+c)^2,x, algorithm="fricas")

[Out]

[1/12*(4*b^2*c*d^3*x^5 - 4*(5*b^2*c^2*d^2 - 6*a*b*c*d^3)*x^3 - 3*(5*b^2*c^3 - 6*a*b*c^2*d + a^2*c*d^2 + (5*b^2
*c^2*d - 6*a*b*c*d^2 + a^2*d^3)*x^2)*sqrt(-c*d)*log((d*x^2 - 2*sqrt(-c*d)*x - c)/(d*x^2 + c)) - 6*(5*b^2*c^3*d
 - 6*a*b*c^2*d^2 + a^2*c*d^3)*x)/(c*d^5*x^2 + c^2*d^4), 1/6*(2*b^2*c*d^3*x^5 - 2*(5*b^2*c^2*d^2 - 6*a*b*c*d^3)
*x^3 + 3*(5*b^2*c^3 - 6*a*b*c^2*d + a^2*c*d^2 + (5*b^2*c^2*d - 6*a*b*c*d^2 + a^2*d^3)*x^2)*sqrt(c*d)*arctan(sq
rt(c*d)*x/c) - 3*(5*b^2*c^3*d - 6*a*b*c^2*d^2 + a^2*c*d^3)*x)/(c*d^5*x^2 + c^2*d^4)]

________________________________________________________________________________________

giac [A]  time = 0.30, size = 114, normalized size = 0.97 \begin {gather*} \frac {{\left (5 \, b^{2} c^{2} - 6 \, a b c d + a^{2} d^{2}\right )} \arctan \left (\frac {d x}{\sqrt {c d}}\right )}{2 \, \sqrt {c d} d^{3}} - \frac {b^{2} c^{2} x - 2 \, a b c d x + a^{2} d^{2} x}{2 \, {\left (d x^{2} + c\right )} d^{3}} + \frac {b^{2} d^{4} x^{3} - 6 \, b^{2} c d^{3} x + 6 \, a b d^{4} x}{3 \, d^{6}} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(x^2*(b*x^2+a)^2/(d*x^2+c)^2,x, algorithm="giac")

[Out]

1/2*(5*b^2*c^2 - 6*a*b*c*d + a^2*d^2)*arctan(d*x/sqrt(c*d))/(sqrt(c*d)*d^3) - 1/2*(b^2*c^2*x - 2*a*b*c*d*x + a
^2*d^2*x)/((d*x^2 + c)*d^3) + 1/3*(b^2*d^4*x^3 - 6*b^2*c*d^3*x + 6*a*b*d^4*x)/d^6

________________________________________________________________________________________

maple [A]  time = 0.01, size = 156, normalized size = 1.32 \begin {gather*} \frac {b^{2} x^{3}}{3 d^{2}}-\frac {a^{2} x}{2 \left (d \,x^{2}+c \right ) d}+\frac {a^{2} \arctan \left (\frac {d x}{\sqrt {c d}}\right )}{2 \sqrt {c d}\, d}+\frac {a b c x}{\left (d \,x^{2}+c \right ) d^{2}}-\frac {3 a b c \arctan \left (\frac {d x}{\sqrt {c d}}\right )}{\sqrt {c d}\, d^{2}}-\frac {b^{2} c^{2} x}{2 \left (d \,x^{2}+c \right ) d^{3}}+\frac {5 b^{2} c^{2} \arctan \left (\frac {d x}{\sqrt {c d}}\right )}{2 \sqrt {c d}\, d^{3}}+\frac {2 a b x}{d^{2}}-\frac {2 b^{2} c x}{d^{3}} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(x^2*(b*x^2+a)^2/(d*x^2+c)^2,x)

[Out]

1/3*b^2*x^3/d^2+2*b/d^2*a*x-2*b^2/d^3*c*x-1/2/d*x/(d*x^2+c)*a^2+1/d^2*x/(d*x^2+c)*a*b*c-1/2/d^3*x/(d*x^2+c)*b^
2*c^2+1/2/d/(c*d)^(1/2)*arctan(1/(c*d)^(1/2)*d*x)*a^2-3/d^2/(c*d)^(1/2)*arctan(1/(c*d)^(1/2)*d*x)*a*b*c+5/2/d^
3/(c*d)^(1/2)*arctan(1/(c*d)^(1/2)*d*x)*b^2*c^2

________________________________________________________________________________________

maxima [A]  time = 2.35, size = 109, normalized size = 0.92 \begin {gather*} -\frac {{\left (b^{2} c^{2} - 2 \, a b c d + a^{2} d^{2}\right )} x}{2 \, {\left (d^{4} x^{2} + c d^{3}\right )}} + \frac {{\left (5 \, b^{2} c^{2} - 6 \, a b c d + a^{2} d^{2}\right )} \arctan \left (\frac {d x}{\sqrt {c d}}\right )}{2 \, \sqrt {c d} d^{3}} + \frac {b^{2} d x^{3} - 6 \, {\left (b^{2} c - a b d\right )} x}{3 \, d^{3}} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(x^2*(b*x^2+a)^2/(d*x^2+c)^2,x, algorithm="maxima")

[Out]

-1/2*(b^2*c^2 - 2*a*b*c*d + a^2*d^2)*x/(d^4*x^2 + c*d^3) + 1/2*(5*b^2*c^2 - 6*a*b*c*d + a^2*d^2)*arctan(d*x/sq
rt(c*d))/(sqrt(c*d)*d^3) + 1/3*(b^2*d*x^3 - 6*(b^2*c - a*b*d)*x)/d^3

________________________________________________________________________________________

mupad [B]  time = 0.08, size = 146, normalized size = 1.24 \begin {gather*} \frac {b^2\,x^3}{3\,d^2}-\frac {x\,\left (\frac {a^2\,d^2}{2}-a\,b\,c\,d+\frac {b^2\,c^2}{2}\right )}{d^4\,x^2+c\,d^3}-x\,\left (\frac {2\,b^2\,c}{d^3}-\frac {2\,a\,b}{d^2}\right )+\frac {\mathrm {atan}\left (\frac {\sqrt {d}\,x\,\left (a\,d-b\,c\right )\,\left (a\,d-5\,b\,c\right )}{\sqrt {c}\,\left (a^2\,d^2-6\,a\,b\,c\,d+5\,b^2\,c^2\right )}\right )\,\left (a\,d-b\,c\right )\,\left (a\,d-5\,b\,c\right )}{2\,\sqrt {c}\,d^{7/2}} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((x^2*(a + b*x^2)^2)/(c + d*x^2)^2,x)

[Out]

(b^2*x^3)/(3*d^2) - (x*((a^2*d^2)/2 + (b^2*c^2)/2 - a*b*c*d))/(c*d^3 + d^4*x^2) - x*((2*b^2*c)/d^3 - (2*a*b)/d
^2) + (atan((d^(1/2)*x*(a*d - b*c)*(a*d - 5*b*c))/(c^(1/2)*(a^2*d^2 + 5*b^2*c^2 - 6*a*b*c*d)))*(a*d - b*c)*(a*
d - 5*b*c))/(2*c^(1/2)*d^(7/2))

________________________________________________________________________________________

sympy [B]  time = 0.87, size = 246, normalized size = 2.08 \begin {gather*} \frac {b^{2} x^{3}}{3 d^{2}} + x \left (\frac {2 a b}{d^{2}} - \frac {2 b^{2} c}{d^{3}}\right ) + \frac {x \left (- a^{2} d^{2} + 2 a b c d - b^{2} c^{2}\right )}{2 c d^{3} + 2 d^{4} x^{2}} - \frac {\sqrt {- \frac {1}{c d^{7}}} \left (a d - 5 b c\right ) \left (a d - b c\right ) \log {\left (- \frac {c d^{3} \sqrt {- \frac {1}{c d^{7}}} \left (a d - 5 b c\right ) \left (a d - b c\right )}{a^{2} d^{2} - 6 a b c d + 5 b^{2} c^{2}} + x \right )}}{4} + \frac {\sqrt {- \frac {1}{c d^{7}}} \left (a d - 5 b c\right ) \left (a d - b c\right ) \log {\left (\frac {c d^{3} \sqrt {- \frac {1}{c d^{7}}} \left (a d - 5 b c\right ) \left (a d - b c\right )}{a^{2} d^{2} - 6 a b c d + 5 b^{2} c^{2}} + x \right )}}{4} \end {gather*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(x**2*(b*x**2+a)**2/(d*x**2+c)**2,x)

[Out]

b**2*x**3/(3*d**2) + x*(2*a*b/d**2 - 2*b**2*c/d**3) + x*(-a**2*d**2 + 2*a*b*c*d - b**2*c**2)/(2*c*d**3 + 2*d**
4*x**2) - sqrt(-1/(c*d**7))*(a*d - 5*b*c)*(a*d - b*c)*log(-c*d**3*sqrt(-1/(c*d**7))*(a*d - 5*b*c)*(a*d - b*c)/
(a**2*d**2 - 6*a*b*c*d + 5*b**2*c**2) + x)/4 + sqrt(-1/(c*d**7))*(a*d - 5*b*c)*(a*d - b*c)*log(c*d**3*sqrt(-1/
(c*d**7))*(a*d - 5*b*c)*(a*d - b*c)/(a**2*d**2 - 6*a*b*c*d + 5*b**2*c**2) + x)/4

________________________________________________________________________________________